package UI;

import java.awt.Button;
import java.awt.Color;
import java.awt.Frame;
import java.awt.Panel;

public class MainFrame extends Frame {
	
	public MainFrame(){
		init();
	}
	
	public MainFrame(String title){
		super(title);
		init();
	}	

	private void init(){
		setSize(400, 400);
		Panel p=new Panel();
		p.setBackground(Color.RED);
		Button b= new Button("Button");
		b.setBackground(Color.BLUE);
		b.setLocation(50, 50);
		b.addActionListener(new ActionButtonListener(this));
		p.add(b);
		b.setBackground(Color.YELLOW);
		add(p);			  
	}
}
